package com.ctgu.server.utils.RandomBag;

import java.util.Random;

public class RandomUtils {

    private static final Random random=new Random();


    public static StringBuilder getRandom(int len){
       return getRandom(len,RandomType.NUM_AND_CHAR);
    }
    public static StringBuilder getRandom(int len,String randomType){
        StringBuilder stringBuilder=new StringBuilder();
        for(int i=0;i<len;i++){
            stringBuilder.append(randomType.charAt(random.nextInt(randomType.length())));
        }
        return stringBuilder;
    }




}
